import request from '@/utils/request'

export default {
    getAllChapterVideo(courseId) {
        return request({
            url: `/eduservice/chapter/getChapterVideo/${courseId}`,
            method: 'get',
          })
    },
    addChapterInfo(info) {
        return request({
            url: `/eduservice/chapter/addChapter`,
            method: 'post',
            data: info
        })
    },
    updateChapterInfo(info) {
        return request({
            url: `/eduservice/chapter/updateChapter`,
            method: 'post',
            data: info
        })
    },
    getChapterInfo(id){
        return request({
            url: `/eduservice/chapter/getChapter/${id}`,
            method: 'get',
        })
    },
    deleteChapterInfo(id){
        return request({
            url: `/eduservice/chapter/deleteChapter/${id}`,
            method: 'delete',
        })
    }
}